<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>诊断报告</title>
    <base th:href="@{http://localhost:9090/}"/>
    <script th:src="@{js/jquery-3.2.1.min.js}"></script>
    <script th:src="@{js/report.js}"></script>
    <style>
        #drugquery{
            margin-top: 30px;
        }
        #drugtable td{
            width: 120px;
        }
        #drughead td{
            background-color: #2b669a;
        }
    </style>
</head>
<body>
<div th:style="'margin: auto'">
    <div>
        <h3 style="text-align: center">就诊表</h3>
    </div>
    <div id="drugquery">
        <table id="drugtable" border="1" cellpadding="0" cellspacing="0"
               th:style="'margin: auto;width:800px'">
            <tr id="drughead">
                <td th:text="药品名称"></td>
                <td th:text="药品编号"></td>
                <td th:text="单价"></td>
                <td th:text="数量"></td>
                <td th:text="操作"></td>
            </tr>
            <tr>
                <td>
                    <input type="text" id="drugName" name="drugName">
                </td>
                <td>
                    <select id="drugNum" name="drugNum">
                        <option>---请选择---</option>
                    </select>
                </td>
                <td id="drugPrice" name="drugPrice">

                </td>
                <td>
                    <input type="text" id="drugNumber">
                </td>
                <td>
                    <!--实际功能为查询-->
                    <input type="button" th:value="添加" id="add">
                </td>
            </tr>
        </table>
    </div>
  <form id="submit" onsubmit="return false">
  <!--<form th:action="@{writereport/towritereport}" method="post">-->
    <table border="1" cellpadding="0" cellspacing="0"
      th:style="'margin: auto;width:800px'">
        <tr>
            <td colspan="4">
                <h4 th:text="就诊表" th:style="'text-align: center'"></h4>
            </td>
        </tr>
        <tr>
            <td th:text="姓名"></td>
            <td>
                <input type="text" th:value="${name}" name="userName" readonly>
                <!--<input type="text" th:value="无" name="userName" >-->
            </td>
            <td th:text="性别"></td>
            <td>
                <input type="text" th:value="${gender}" name="userGender" readonly>
                <!--<input type="text" th:value="无">-->
            </td>
        </tr>
        <tr>
            <td th:text="会诊科室"></td>
            <td>
                <!--<input type="text" th:value="${session.userSession.dDepartment}" name="recordDepartment" id="recordDepartment">-->
                <input type="text" name="recordDepartment" id="recordDepartment" readonly>
                <!--<input type="text" th:value="无" name="recordDepartment">-->
                <input type="hidden" th:value="${session.userSession.dId}"  id="doctorId">
            </td>
            <td th:text="住院床号"></td>
            <td>
                <input type="text" name="bedNum">
            </td>
        </tr>
        <tr>
            <td th:text="诊断标题"></td>
            <td colspan="3">
                <input type="text" name="recordTitle">
            </td>
            <!--<td colspan="2" th:text="开单日期">-->
            <!--<td th:text="开单日期"></td>
            <td>
                <input type="date" name="recordTime">
            </td>-->
        </tr>
        <tr>
            <td th:text="诊断信息"></td>
            <td colspan="3">
                <input type="text" name="recordDocument">
            </td>
        </tr>
        <tr>
            <td colspan="4">
                <strong th:text="所需药品"></strong>
                <div id="addDrug" style="height: 150px;overflow: auto" >
                    <input type="text" value="药品名称"><input type="text" value="药品编号"><input type="text" value="单价"><input type="text" value="数量"><br>
                </div>
            </td>
        </tr>

        <tr>
            <td colspan="4">
                <p>
                    <span>就诊医生:</span>
                    <input type="text" name="doctorName" th:value="${session.userSession.dName}" readonly/>
                </p>
            </td>
        </tr>
    </table>
      <input type="hidden" name="userId" th:value="1">
      <input type="hidden" name="doctorId" th:value="2">

      <div th:style="'text-align: center'">
          <input type="submit"  th:value="提交">
          <input type="button" th:value="取消" id="back">
      </div>
  </form>
</div>
</body>
</html>